/**
 * 版权所有(C)，上海勾芒信息科技，2017，所有权利保留。
 * 
 * 项目名：	cards-web
 * 文件名：	ModifyWxAppDomain.java
 * 模块说明：	
 * 修改历史：
 * 2017年5月26日 - Debenson - 创建。
 */
package me.chanjar.weixin.component.bean.author;

import java.io.Serializable;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonProperty;
import com.google.common.collect.Lists;

/**
 * 小程序的安全域名
 * 
 * @author Debenson
 * @since 0.1
 */
public class WxAppDomains implements Serializable {
  private static final long serialVersionUID = 726794295927904624L;

  @JsonProperty("requestdomain")
  private List<String> requestDomains;
  @JsonProperty("wsrequestdomain")
  private List<String> wsrequestDomains;
  @JsonProperty("uploaddomain")
  private List<String> uploadDomains;
  @JsonProperty("downloaddomain")
  private List<String> downloadDomains;

  public WxAppDomains addRequestDomains(String... domains) {
    if (requestDomains == null) {
      requestDomains = Lists.newArrayList();
    }
    requestDomains.addAll(Lists.newArrayList(domains));
    return this;
  }

  public WxAppDomains addWsrequestDomains(String... wsdomains) {
    if (wsrequestDomains == null) {
      wsrequestDomains = Lists.newArrayList();
    }
    wsrequestDomains.addAll(Lists.newArrayList(wsdomains));
    return this;
  }

  public WxAppDomains addUploadDomains(String... domains) {
    if (uploadDomains == null) {
      uploadDomains = Lists.newArrayList();
    }
    uploadDomains.addAll(Lists.newArrayList(domains));
    return this;
  }

  public WxAppDomains addDownloadDomains(String... domains) {
    if (downloadDomains == null) {
      downloadDomains = Lists.newArrayList();
    }
    downloadDomains.addAll(Lists.newArrayList(domains));
    return this;
  }

  public List<String> getRequestDomains() {
    return requestDomains;
  }

  public void setRequestDomains(List<String> requestDomains) {
    this.requestDomains = requestDomains;
  }

  public List<String> getWsrequestDomains() {
    return wsrequestDomains;
  }

  public void setWsrequestDomains(List<String> wsrequestDomains) {
    this.wsrequestDomains = wsrequestDomains;
  }

  public List<String> getUploadDomains() {
    return uploadDomains;
  }

  public void setUploadDomains(List<String> uploadDomains) {
    this.uploadDomains = uploadDomains;
  }

  public List<String> getDownloadDomains() {
    return downloadDomains;
  }

  public void setDownloadDomains(List<String> downloadDomains) {
    this.downloadDomains = downloadDomains;
  }

}
